package com.fita.wechat.dao;

import java.util.List;

import com.demo2do.core.persistence.annotation.Dao;
import com.demo2do.core.persistence.annotation.Query;
import com.demo2do.core.persistence.annotation.Variable;
import com.fita.entity.data.SpecialEquipment;
import com.fita.entity.order.Order;
import com.fita.entity.order.OrderSpecialEquipment;

/**
 * 
 * @author dan
 *
 */
@Dao("hibernate")
public interface SpecialEquipmentDao {
    
    /**
     * 
     * @param types
     * @return
     */
    @Query("FROM SpecialEquipment WHERE type in(:types)")
    public List<SpecialEquipment> list(@Variable("types") String[] types);
    
    /**
     * 
     * @param order
     * @return
     */
    @Query("FROM OrderSpecialEquipment WHERE order = :order")
    public List<OrderSpecialEquipment> list(@Variable("order") Order order);

}
